package com.miyu.system.pojo.system;

import cn.hutool.core.date.LocalDateTimeUtil;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.miyu.system.utils.jpacomment.annotation.ColumnComment;
import com.miyu.system.utils.jpacomment.annotation.TableComment;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.persistence.*;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

import lombok.Data;

/**
 * 系统参数设置;
 * @author : miyu
 * @date : 2024-9-18
 */
@ApiModel(value = "系统参数设置",description = "")
@Data
@Entity
@Table(name="sys_param_config")
@TableComment("系统参数设置")
public class SysParamConfig implements Serializable,Cloneable{
    /** 主键;主键 */
    @Id
    @TableGenerator(name="id_gen",  table="sys_id_generator", pkColumnName="table_name", pkColumnValue="sys_param_config", valueColumnName="id_value", initialValue=1, allocationSize=1)
    @GeneratedValue(strategy=GenerationType.TABLE, generator="id_gen")
    @ApiModelProperty(value="主键",notes = "主键")
    @Column(name = "id", nullable = false,length=16 )
    @ColumnComment("主键")
    private Integer id ;
    /** 参数编码;参数编码 */
    @ApiModelProperty(value="参数编码",notes = "参数编码")
    @Column(name = "param_code", nullable = false,length=30 )
    @ColumnComment("参数编码")
    private String paramCode ;
    /** 参数名称;参数名称 */
    @ApiModelProperty(value="参数名称",notes = "参数名称")
    @Column(name = "param_name", nullable = false,length=50 )
    @ColumnComment("参数名称")
    private String paramName ;
    /** 使用模块;使用模块 */
    @ApiModelProperty(value="使用模块",notes = "使用模块")
    @Column(name = "sys_mod", nullable = true,length=20 )
    @ColumnComment("使用模块")
    private String sysMod ;
    /** 参数值;参数值 */
    @ApiModelProperty(value="参数值",notes = "参数值")
    @Column(name = "param_set", nullable = false,length=1000 )
    @ColumnComment("参数值")
    private String paramSet ;
    /** 是否停用;是否停用 */
    @ApiModelProperty(value="是否停用",notes = "是否停用")
    @Column(name = "is_stop", nullable = true,length=2 )
    @ColumnComment("是否停用")
    private String isStop ;
    /** 备注;备注 */
    @ApiModelProperty(value="备注",notes = "备注")
    @Column(name = "remark", nullable = true,length=100 )
    @ColumnComment("备注")
    private String remark ;
    /** 创建日期;创建日期 */
    @ApiModelProperty(value="创建日期",notes = "创建日期")
    @Column(name = "create_date", nullable = true )
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @ColumnComment("创建日期")
    private LocalDateTime createDate = LocalDateTimeUtil.now();
}